﻿using iWare.Wms.Core;
using iWare.Wms.Core.Service;
using System.ComponentModel.DataAnnotations;

namespace iWare.Wms.Application
{
    
    /// <summary>
    /// 任务管理查询参数
    /// </summary>
    public class WmsTaskSearch : PageInputBase
    {
        /// <summary>
        /// 任务号
        /// </summary>
        public virtual string Taskno { get; set; }

        /// <summary>
        /// 任务方式
        /// </summary>
        public virtual iWare.Wms.Core.Enum.TaskModel? Taskmodel { get; set; }

        /// <summary>
        /// 任务类型
        /// </summary>
        public virtual iWare.Wms.Core.Enum.TaskType? Tasktype { get; set; }

        /// <summary>
        /// 任务级别
        /// </summary>
        public virtual int? Tasklevel { get; set; }

        /// <summary>
        /// 任务状态
        /// </summary>
        public virtual iWare.Wms.Core.Enum.TaskStatus? Taskstatus { get; set; }

        /// <summary>
        /// 任务状态
        /// </summary>
        public virtual string Taskcontentstring { get; set; }

        /// <summary>
        /// 托盘编号
        /// </summary>
        public virtual string ContainerCode { get; set; }

        /// <summary>
        /// 起始库位
        /// </summary>
        public virtual string Sourceplace { get; set; }

        /// <summary>
        /// 目标库位
        /// </summary>
        public virtual string Toplace { get; set; }

        /// <summary>
        /// 巷道
        /// </summary>
        public virtual int? Aisle { get; set; }

        /// <summary>
        /// 库区名称
        /// </summary>
        public virtual string AreaName { get; set; }

        /// <summary>
        /// 组盘记录ID
        /// </summary>
        public virtual string Ordersid { get; set; }

        /// <summary>
        /// 发送次数
        /// </summary>
        public virtual int? Sendtimes { get; set; }

        /// <summary>
        /// 任务处理状态
        /// </summary>
        public virtual int? Handelstatus { get; set; }

        /// <summary>
        /// 是否生效
        /// </summary>
        public virtual iWare.Wms.Core.YesOrNot? Void { get; set; }

        /// <summary>
        /// 正在执行的任务
        /// </summary>
        public virtual iWare.Wms.Core.YesOrNot? Iscurrenttask { get; set; }

        /// <summary>
        /// 是否是最后执行的任务
        /// </summary>
        public virtual iWare.Wms.Core.YesOrNot? Islasttask { get; set; }

        /// <summary>
        /// 正在执行的任务
        /// </summary>
        public virtual iWare.Wms.Core.YesOrNot? Isemptycontainer { get; set; }

        /// <summary>
        /// 任务执行堆垛机ID
        /// </summary>
        public virtual int? Dodeviceid { get; set; }

        /// <summary>
        /// 设备执行节点ID
        /// </summary>
        public virtual string Dodevicenodeid { get; set; }

        /// <summary>
        /// 设备类型
        /// </summary>
        public virtual string Dodevicetype { get; set; }

    }

    /// <summary>
    /// 任务管理输入参数
    /// </summary>
    public class WmsTaskInput
    {
        /// <summary>
        /// 任务号
        /// </summary>
        public virtual string Taskno { get; set; }

        /// <summary>
        /// 任务方式
        /// </summary>
        public virtual iWare.Wms.Core.Enum.TaskModel Taskmodel { get; set; }

        /// <summary>
        /// 任务类型
        /// </summary>
        public virtual iWare.Wms.Core.Enum.TaskType Tasktype { get; set; }

        /// <summary>
        /// 任务级别
        /// </summary>
        public virtual int Tasklevel { get; set; }

        /// <summary>
        /// 任务状态
        /// </summary>
        public virtual iWare.Wms.Core.Enum.TaskStatus Taskstatus { get; set; }

        /// <summary>
        /// 任务状态
        /// </summary>
        public virtual string Taskcontentstring { get; set; }

        /// <summary>
        /// 托盘编号
        /// </summary>
        public virtual string ContainerCode { get; set; }

        /// <summary>
        /// 起始库位
        /// </summary>
        public virtual string Sourceplace { get; set; }

        /// <summary>
        /// 目标库位
        /// </summary>
        public virtual string Toplace { get; set; }

        /// <summary>
        /// 巷道
        /// </summary>
        public virtual int Aisle { get; set; }

        /// <summary>
        /// 库区名称
        /// </summary>
        public virtual string AreaName { get; set; }

        /// <summary>
        /// 组盘记录ID
        /// </summary>
        public virtual string Ordersid { get; set; }

        /// <summary>
        /// 发送次数
        /// </summary>
        public virtual int Sendtimes { get; set; }

        /// <summary>
        /// 任务处理状态
        /// </summary>
        public virtual int Handelstatus { get; set; }

        /// <summary>
        /// 是否生效
        /// </summary>
        public virtual iWare.Wms.Core.YesOrNot Void { get; set; }

        /// <summary>
        /// 正在执行的任务
        /// </summary>
        public virtual iWare.Wms.Core.YesOrNot Iscurrenttask { get; set; }

        /// <summary>
        /// 是否是最后执行的任务
        /// </summary>
        public virtual iWare.Wms.Core.YesOrNot Islasttask { get; set; }

        /// <summary>
        /// 正在执行的任务
        /// </summary>
        public virtual iWare.Wms.Core.YesOrNot Isemptycontainer { get; set; }

        /// <summary>
        /// 任务执行堆垛机ID
        /// </summary>
        public virtual int Dodeviceid { get; set; }

        /// <summary>
        /// 设备执行节点ID
        /// </summary>
        public virtual string Dodevicenodeid { get; set; }

        /// <summary>
        /// 设备类型
        /// </summary>
        public virtual string Dodevicetype { get; set; }

    }

    public class AddWmsTaskInput : WmsTaskInput
    {
    }

    public class DeleteWmsTaskInput : BaseId
    {
    }

    public class UpdateWmsTaskInput : WmsTaskInput
    {
        /// <summary>
        /// Id主键
        /// </summary>
        [Required(ErrorMessage = "Id主键不能为空")]
        public long Id { get; set; }

    }

    public class QueryeWmsTaskInput : BaseId
    {

    }
}
